<html><head>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script>
<link href="src/prettify.css" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="src/prettify.js"></script>
	
</head>
<body>
<script type='text/javascript'>
$(function(){

$('#b1').click(function(){
x = $('textarea').val();
$('#tt').html(htmlEscape(x));
prettyPrint();
});

});
function htmlEscape(str) {
    return String(str)
            .replace(/&/g, '&amp;')
            .replace(/"/g, '&quot;')
            .replace(/'/g, '&#39;')			
            .replace(/</g, '&lt;')            			
            .replace(/>/g, '&gt;')
            .replace(/ /g, '&nbsp;')
			.replace(/\n/g, '<br\>');
}
</script>


 <textarea cols='50' rows='20'>
 </textarea>
 <button id='b1'>make code</button>
 <pre class="prettyprint" id='tt'>
</pre>

</body>
</html>